/// @description Insert description here
// You can write your code in this editor
draw_sprite(sShadow, 0, floor(x), floor(y));
if(state == PlayerStateHook) && (image_index != 3) DrawHookChain();
if(invulnerable != 0)&& ((invulnerable mod 8 < 2) ==0) && (flash == 0)
{
	//跳过绘制函数（闪烁）
}
else
{
	if (flash != 0)
	{
		shader_set(flashShader);
		uFlash = shader_get_uniform(flashShader, "flash");
		shader_set_uniform_f(uFlash, flash);
	}
	draw_sprite_ext(
		sprite_index,
		image_index,
		floor(x),
		floor(y - z),
		image_xscale,
		image_yscale,
		image_angle,
		image_blend,
		image_alpha
);
	if(shader_current() != -1) shader_reset();

}
if(state == PlayerStateHook) && (image_index == 3) DrawHookChain();
function DrawHookChain()
{
	var _originX = floor(x);
	var _originY = floor(y) - 7;//player的y在底部，因此需要-7将发射坐标上移
	//钩子方向
	var _hookDirX = sign(hookX);
	var _hookDirY = sign(hookY);
	//钩子中间链条个数
	var _chains = hook div hookSize;
	for(var i = 0; i < _chains; i++)
	{
		draw_sprite(
		sHookChain,
		0,
		_originX + _hookDirX * i * hookSize,
		_originY + _hookDirY * i * hookSize)
	}
	draw_sprite(sHookBlade, image_index, _originX + hookX, _originY + hookY);
	
}
